package com.tuyenmonkey.mkloader.model;

import ohos.agp.render.Canvas;
import ohos.agp.utils.Point;

/**
 * Created by Tuyen Nguyen on 2/10/17.
 */

public class Circle extends GraphicObject {
  private Point center;
  private float radius;

  public Circle() {
    center = new Point();
  }

  public void setRadius(float radius) {
    this.radius = radius;
  }

  public void setCenter(float x,float y) {
    center.modify(x, y);
  }

  @Override public void draw(Canvas canvas) {
    canvas.drawCircle(center.getPointX(), center.getPointY(), radius, paint);
  }
}
